<template>
<NavBar />
  <router-view></router-view>
</template>


<script>
import NavBar from './components/NavBar.vue'
import "bootstrap/dist/css/bootstrap.min.css"
import "bootstrap/dist/js/bootstrap" 
/* import $ from 'jquery' */

export default{
  components: {
    NavBar
  },

   setup() {
   /* $.ajax({
  url: "http://localhost:3000/user/account/token/", 
      type: "post",
      data: { // 往后端传的各种参数
        username:'wusihao',
        password:'wusihao',
      },

      success(resp) {
        console.log(resp);
      },
      error(resp) {
        console.log(resp);
      }
    });

    $.ajax({ // 与后端建立联系， 刷新某一局部业面而不刷新整个业面
      url: "http://localhost:3000/user/account/info/", 需要访问的后端的地址
      type: "get", // 请求方式
      headers: {
        Authorization: "Bearer " + "eyJhbGciOiJIUzI1NiJ9.eyJqdGkiOiI1YWI0YTdiNDE4ODM0NzBjOTYwYTQ5YThkZmExN2M1YyIsInN1YiI6IjEiLCJpc3MiOiJzZyIsImlhdCI6MTY2NjkyMDk1MCwiZXhwIjoxNjY4MTMwNTUwfQ.INDX_oF-yUHDZBBTmYGMlBsDVUCXDcwPa2IbE2ZdfFY"

      },

      success(resp) { // 若成功resp存的是从后端取回的数据
        
        console.log(resp);
      },
      error(resp) {
        console.log(resp);
      }
    })

    $.ajax({
      url:"http://localhost:3000/user/account/register/",
      type:"post",
      data: {
        username:"wsh3",
        password:"wusihao",
        confirmedPassword:"wusihao",
      },

      success(resp){
        console.log(resp);
      },
      error(resp) {
        console.log(resp);
      }
    })*/
  } 


}
</script>


<style>
body{
background: url("./assets/images/download.jpg") no-repeat;
height:100%;
width:100%;
overflow: hidden;
background-size:cover;
}
</style>
